/*
* $Id: NavigationWin.h 31 2010-02-17 16:55:56Z volok-aleksej@yandex.ru $
*
* Copyright 2008-2009 by Volokitin Alexey
* All rights reserved
*
*/
#ifndef _NAVIGATION_WIN_H_
#define _NAVIGATION_WIN_H_

#include "JournalDefined.h"

class CNavigationWin : public CTreeCtrl, public ISubscriber
{
protected:
	void Reload();
	void SetMenuItem(CMenu* menu, int nNum, int nId, const std::tstring& strText, BOOL bSep);
	void CreateMenu(CPoint pos);
	void ItemManipulation(JournalEnum::typeItemMnpl item);
protected:
	DECLARE_MESSAGE_MAP();
	afx_msg void OnRButtonDown(UINT nFlags, CPoint point);
	afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
	afx_msg void OnContextMenu(CWnd* pWnd, CPoint pos);
	afx_msg void OnAddPoint();
	afx_msg void OnAddFamily();
	afx_msg void OnAddInspect();
	afx_msg void OnChangePoint();
	afx_msg void OnChangeFamily();
	afx_msg void OnDeletePoint();
	afx_msg void OnDeleteFamily();
public:
	CNavigationWin();
	virtual ~CNavigationWin();
public:
	void WindowCreate(CWnd* pParentWin);
	virtual void EventHandler();
};

#endif/*_NAVIGATION_WIN_H_*/